/*
 * igo: com.cctv.igo.admin.scheduler.dto.Trigger.java Create On 2011-5-4 下午09:41:43 By Q-Wang
 * $Revision: 1.1 $
 */
package com.ctvit.scheduler.dto;

import com.ctvit.scheduler.common.Copier;
import com.ctvit.scheduler.domain.QrtxTrigger;

/**
 * @author <a href="mailto:apeidou@gmail.com">Q-Wang</a>
 *
 */
public class Trigger extends QrtxTrigger {

	public Trigger() {}

	public Trigger(QrtxTrigger trigger) {
		populate(trigger);
	}

	public void populate(QrtxTrigger trigger) {
		Copier.COPIER_TRIGGER.copy(trigger, this, null);
	}

	public void setEnabledBoolean(boolean enabled) {
		setEnabled(enabled?1:0);
	}

	public boolean getEnabledBoolean() {
		return getEnabled()!=0;
	}
}
